/****** Object:  Stored Procedure dbo.spr_UpdateDBRolesByPK  ******/

 use [TourIS]
 GO

 if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[spr_UpdateDBRolesByPK]') and OBJECTPROPERTY(id, N'IsProcedure') = 1)
 drop procedure [dbo].[spr_UpdateDBRolesByPK]
 GO

 SET QUOTED_IDENTIFIER OFF
 GO
 SET ANSI_NULLS OFF
 GO

 CREATE  PROCEDURE [dbo].[spr_UpdateDBRolesByPK]
 (
	@remarks varchar(50),
	@roleid int,
	@rolename varchar(50)
 )

 AS

 BEGIN
	SET NOCOUNT ON
	DECLARE @Err int

	UPDATE [Roles]
	SET
		[Remarks] = @remarks,
		[RoleId] = @roleid,
		[RoleName] = @rolename

	WHERE
	[RoleId] = @roleid


	SET @Err = @@Error
	RETURN @Err
 END

 SET QUOTED_IDENTIFIER OFF
 GO
 SET ANSI_NULLS ON
 GO

